import request from '@/utils/request';
import { baseUrl } from '@/utils/settings';

//查询个人通讯录分组
export async function selLv1ByUserId(param) {
    return request(baseUrl + 'telBook/selLv1ByUserId',{ method:'get', data: param.payload}, param.type);
}
//查询企业通讯录分组
export async function selLv1ByType2(param) {
    return request(baseUrl + 'telBook/selLv1ByType2',{ method:'get', data: param.payload}, param.type);
}
//添加通讯录分组
export async function addTelBookGroup(param) {
    return request(baseUrl + 'telBook/addTelBookGroup',{ method:'post', data: param.payload}, param.type);
}
//删除通讯录分组
export async function delTelBookGroup(param) {
    return request(baseUrl + 'telBook/delTelBookGroup',{ method:'post', data: param.payload}, param.type);
}
//修改通讯录分组
export async function updateTelBookGroup(param) {
    return request(baseUrl + 'telBook/updateTelBookGroup',{ method:'post', data: param.payload}, param.type);
}
//查询个人通讯录
export async function selTelBookByUserId(param) {
    return request(baseUrl + 'telBook/selTelBookByUserId',{ method:'post', data: param.payload}, param.type);
}
//查询企业通讯录
export async function selTelBookByEnterprise(param) {
    return request(baseUrl + 'telBook/selTelBookByEnterprise',{ method:'post', data: param.payload}, param.type);
}
//添加通讯录
export async function addTelBook(param) {
    return request(baseUrl + 'telBook/addTelBook',{ method:'post', data: param.payload.upAddInfo}, param.type);
}
//修改通讯录
export async function updateTelBook(param) {
    return request(baseUrl + 'telBook/updateTelBook',{ method:'post', data: param.payload.upAddInfo}, param.type);
}
//删除通讯录
export async function delTelBook(param) {
    return request(baseUrl + 'telBook/delTelBook',{ method:'post', data: param.payload}, param.type);
}